<!DOCTYPE html>
<html lang="zh">
<head>
	<title>${content.title} - ${category.name}</title>
	<meta name="keywords" content="<#list getKeywords(content.title) as a>${a}<#sep>,</#list>"/>
	<meta name="description" content="${content.description!}"/>
<@_includePlace path="/76c53ac2-4f88-4ef3-984b-c81d00a48089.html"/> <#-- 头部Header -->
</head>
<body>
<@_includePlace path="/index.html/2ecdebcc-c087-4ed3-aecd-80f85ce6a6c6.html"/> <#-- 导航 -->
<main>
	<div class="container bread">
		<@include path="/ftl/echoBread.ftl"/>
		<@echoBread category.id/>
	</div>
	<div class="container">
		<article class="left-content">
			<header>
				<h1><a href="${url!}">${content.title}</a></h1>
				<p class="author">${content.author!} ${content.editor!} ${content.publishDate?datetime} 阅读:<em>loading...</em></p>
				<#if content.copied><p class="author">来源：${(attribute.source)!} ${(attribute.sourceUrl)!}</p></#if>
			</header>
			<div id="content">${text?no_esc!}</div>
			<div><@_tag ids=content.tagIds><#if map?has_content>标签:</#if><#list map?keys as k><a href="//search.publiccms.com/?tagId=${k}" target="_blank">${map[k].name}</a><#sep>,</#list></@_tag></div>
			<@include path="/ftl/content_page.ftl"/>
			<@import path="/ftl/tools.ftl" namespace="t"/>
			<@include path="/ftl/comment.ftl"/><#-- 评论 -->
		</article>
		<aside>
			<@_includePlace path="/category/list.html/49d393ca-f0f1-4723-a9b0-6f9b6d7cc04d.html"/> <#-- 编辑推荐 -->
			<@_includePlace path="/category/list.html/3435e9a7-565a-4f93-8670-9c272a1d51cc.html"/> <#-- 精彩图集 -->
			<div style="border-bottom: 1px solid #eee;">
				<a href="${siteAttribute.searchPath!}?tagId=${content.tagIds!}" target="_blank"><h3>相关推荐</h3></a>
				<ul>
<#assign related=[content.id]/>
<@_contentRelatedList contentId=content.id count=11-related?size>
	<#list page.list as a>
                	<li><a href="${a.url!}" target="_blank" title="${a.title}"><@t.cut a.title 20 '...'/></a></li>
					<#assign related+=[a.id]/>
	</#list>
</@_contentRelatedList>
<#if content.tagIds?has_content && related?size lt 10>
	<@_search tagId=content.tagIds count=11-related?size>
		<#list page.list as a>
                 	<#if !related?seq_contains(a.id)>
						<li><a href="<#if a.onlyUrl>${site.dynamicPath}content/redirect.do?id=${a.id}<#else>${a.url}</#if>" title="${a.title}"><@t.cut a.title 20 '...'/></a></li>
						<#assign related+=[a.id]/>
					</#if>
		</#list>
	</@_search>
</#if>
<#if related?size lt 10>
		<@_contentList categoryId=category.id count=11-related?size>
				<#list page.list as a>
					<#if !related?seq_contains(a.id)>
						<li><a href="<#if a.onlyUrl>${site.dynamicPath}content/redirect.do?id=${a.id}<#else>${a.url}</#if>" title="${a.title}"><@t.cut a.title 20 '...'/></a></li>
					</#if>
				</#list>
		</@_contentList>
</#if>
				</ul>
			</div>
		</aside>
	</div>
	<div class="clearfix-before"></div>
</main>
<@_includePlace path="/cc29e896-332a-46d8-9bcb-d48e92144e9c.html"/> <#-- 尾部Footer -->
<script>
	uParse('#content',{rootPath: '${site.sitePath!}assets/ueditor'});
	$('article #content img').each(function(){
		if(!$(this).parent('a').length) {
			$(this).wrapAll("<a href=\"" + $(this).attr("src") + "\" target=\"_blank\" title=\"点击查看图片\"></a>");
		}
	});
	$.getJSON('${site.dynamicPath!}api/contentClick?id=${content.id}', function(data){
		$('article .author em').text(data.clicks);
	});
</script>
</body>
</html>